﻿<UserControl xmlns:sdk="http://schemas.microsoft.com/winfx/2006/xaml/presentation/sdk"  
  x:Class="QLNS.MainPage"
  xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" 
  xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
  xmlns:navigation="clr-namespace:System.Windows.Controls;assembly=System.Windows.Controls.Navigation" 
  xmlns:uriMapper="clr-namespace:System.Windows.Navigation;assembly=System.Windows.Controls.Navigation"
  xmlns:dataControls="clr-namespace:System.Windows.Controls;assembly=System.Windows.Controls.Data.DataForm.Toolkit" 
  xmlns:login="clr-namespace:QLNS.LoginUI"
  xmlns:d="http://schemas.microsoft.com/expression/blend/2008" xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" 
   xmlns:telerik="http://schemas.telerik.com/2008/xaml/presentation"
  mc:Ignorable="d" d:DesignWidth="640" d:DesignHeight="480">

    <Grid x:Name="LayoutRoot" Style="{StaticResource LayoutRootGridStyle}">

        <Grid x:Name="Content" Margin="0,63,0,0">
            <Grid.ColumnDefinitions>
                <ColumnDefinition Width="auto" />
                <ColumnDefinition Width="*"/>
            </Grid.ColumnDefinitions>

            <telerik:RadOutlookBar x:Name="outlookBar" Padding="10" Grid.Column="0" Width="200" MaxWidth="200"  telerik:StyleManager.Theme="Expression_Dark" Align="Left" >
                <!--	*** MAIL ******	-->
                <telerik:RadOutlookBarItem Header="Mail" Icon="../Images/OutlookBar/mailBig.png"
					SmallIcon="../Images/OutlookBar/mailSmall.png" Content="Mail" MouseLeftButtonUp="RadOutlookBarItem_MouseLeftButtonUp" />
                <!--	*** CALENDAR ***	-->
                <telerik:RadOutlookBarItem Header="Calendar"
					Icon="../Images/OutlookBar/calendarBig.png"
					SmallIcon="../Images/OutlookBar/calendarSmall.png" Content="Calendar" />
                <!--	*** CONTACTS ***	-->
                <telerik:RadOutlookBarItem Header="Contacts"
					Icon="../Images/OutlookBar/contactsBig.png"
					SmallIcon="../Images/OutlookBar/contactsSmall.png" Content="Contacts" />
                <!--	*** TASKS ***	-->
                <telerik:RadOutlookBarItem Header="Tasks"
					Icon="../Images/OutlookBar/tasksBig.png"
					SmallIcon="../Images/OutlookBar/tasksSmall.png" Content="Tasks" />
                <!--	*** NOTES ***	-->
                <telerik:RadOutlookBarItem Header="Notes"
					Icon="../Images/OutlookBar/notesBig.png"
					SmallIcon="../Images/OutlookBar/notesSmall.png" Content="Notes" />
                <!--	*** FOLDER LIST ***	-->
                <telerik:RadOutlookBarItem Header="Folder List"
					Icon="../Images/OutlookBar/foldersBig.png"
					SmallIcon="../Images/OutlookBar/foldersSmall.png" Content="Folder List" />
            </telerik:RadOutlookBar>
            <Border x:Name="ContentBorder" Style="{StaticResource ContentBorderStyle}" Grid.Column="1" >
                <navigation:Frame x:Name="ContentFrame" Style="{StaticResource ContentFrameStyle}" 
                              Source="/Home" Navigated="ContentFrame_Navigated" NavigationFailed="ContentFrame_NavigationFailed">
                    <navigation:Frame.UriMapper>
                        <uriMapper:UriMapper>
                            <uriMapper:UriMapping Uri="" MappedUri="/Views/Home.xaml"/>
                            <uriMapper:UriMapping Uri="/{pageName}" MappedUri="/Views/{pageName}.xaml"/>
                        </uriMapper:UriMapper>
                    </navigation:Frame.UriMapper>
                </navigation:Frame>
            </Border>
        </Grid>
        
        <Grid Style="{StaticResource NavigationOuterGridStyle}">
            <Grid x:Name="NavigationGrid" Style="{StaticResource NavigationGridStyle}">

                <Border x:Name="BrandingBorder" Style="{StaticResource BrandingBorderStyle}">
                    <StackPanel x:Name="BrandingStackPanel" Style="{StaticResource BrandingStackPanelStyle}">
                        <ContentControl Style="{StaticResource LogoIcon}"/>
                        <TextBlock x:Name="ApplicationNameTextBlock" Style="{StaticResource ApplicationNameStyle}" 
                               Text="{Binding Strings.ApplicationName, Source={StaticResource ApplicationResources}}"/>

                    </StackPanel>
                </Border>

                <Border x:Name="LinksBorder" Style="{StaticResource LinksBorderStyle}">
                    <StackPanel x:Name="LinksStackPanel" Style="{StaticResource LinksStackPanelStyle}">

                        <HyperlinkButton x:Name="Link1" Style="{StaticResource LinkStyle}" 
                                     NavigateUri="/Home" TargetName="ContentFrame" Content="{Binding Path=Strings.HomePageTitle, Source={StaticResource ApplicationResources}}"/>
                        <Rectangle x:Name="Divider2" Style="{StaticResource DividerStyle}"/>

                        <HyperlinkButton x:Name="Link3" Style="{StaticResource LinkStyle}" 
                                     NavigateUri="/Employee" TargetName="ContentFrame" Content="{Binding Path=Strings.EmployeePageTitle, Source={StaticResource ApplicationResources}}"/>

                        <Rectangle x:Name="Divider1" Style="{StaticResource DividerStyle}"/>

                        <HyperlinkButton x:Name="Link2" Style="{StaticResource LinkStyle}" 
                                     NavigateUri="/About" TargetName="ContentFrame" Content="{Binding Path=Strings.AboutPageTitle, Source={StaticResource ApplicationResources}}"/>

                    </StackPanel>
                </Border>

            </Grid>

            <Border Style="{StaticResource LoginContainerStyle}">
                <login:LoginStatus/>
            </Border>
        </Grid>

    </Grid>

</UserControl>